﻿$(window).load(function() {
    // Setting banner animation
    $('#slider').nivoSlider({
        effect: 'fade', // Specify sets like: 'fold,fade,sliceDown'
        slices: 15, // For slice animations
        boxCols: 8, // For box animations
        boxRows: 4, // For box animations
        animSpeed: 500, // Slide transition speed
        pauseTime: 5000, // How long each slide will show
        startSlide: 0, // Set starting Slide (0 index)
        directionNav: true, // Next & Prev navigation
        directionNavHide: true, // Only show on hover
        controlNav: true, // 1,2,3... navigation
        controlNavThumbs: false, // Use thumbnails for Control Nav
        controlNavThumbsFromRel: false, // Use image rel for thumbs
        controlNavThumbsSearch: '.jpg', // Replace this with...
        controlNavThumbsReplace: '_thumb.jpg', // ...this in thumb Image src
        keyboardNav: false, // Use left & right arrows
        pauseOnHover: false, // Stop animation while hovering
        manualAdvance: false, // Force manual transitions
        captionOpacity: 0.6, // Universal caption opacity
        prevText: 'Quay lại', // Prev directionNav text
        nextText: 'Tiếp theo', // Next directionNav text
        randomStart: false // Start on a random slide
        
    });
    
    // Using custom configuration
    $("#foo0").carouFredSel({
	    items				: 6,
	    direction			: "left",
	    prev: '#prevdt',
		next: '#nextdt',
	    scroll : {
		    items			: 1,
		    /*easing			: "duration",*/
		    duration		: 500							
		    /*pauseOnHover	: true*/
	    }					
    });
    $("#foo1").carouFredSel({
	    items				: 3,
	    direction			: "left",
	    prev: '#prev',
		next: '#next',
		auto: false,
	    scroll : {
		    items			: 1,
		    /*easing			: "duration",*/
		    duration		: 300							
		    /*pauseOnHover	: true*/
	    }					
    });	
});

